package com.hn.service.Impl;

import com.hn.dao.StudentDao;
import com.hn.pojo.Student;
import com.hn.service.StudentService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * @作者 : wangchangdian
 * @创建时间 : 2019/3/26 - 22:16
 */
@Service("studentService")
public class StudentServiceImpl implements StudentService {
    @Resource
    StudentDao studentDao;
    @Override
    public void addStu(Student student) {
        studentDao.addStu(student);
    }

    @Override
    public Student findStu(int ID) {
        return studentDao.findStu(ID);
    }

    @Override
    public List<Student> findAllStu() {
        return studentDao.findAllStu();
    }

    //修改学生信息
    public void editStu(Student StuName){
        studentDao.editStu(StuName);
    }

    @Override
    public void deleteStu(int ID) {
        studentDao.deleteStu(ID);
    }
}
